function setSidebarActive(th) {
    $(th).parent("li").siblings().removeClass("active");
    $(th).parent("li").addClass("active");
}

function getCheckId() {
    var size = $("input:checkbox:checked").length;
    if (size == 0) {
        return;
    } else {
        var input = $('input[type=checkbox]:checked');
        var ids =[];
        for (var i = 0; i < input.length; i++) {
            ids[i] = $(input[i]).val();
        }
        return ids;
    }
}

function formSubmit(url, sTarget) {
    document.forms[0].target = sTarget;
    document.forms[0].action = url;
    document.forms[0].submit();
    return true;
}